// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue';
import App from './App';
// 路由
import router from './router';
// 状态管理
import store from '@/store/index.js';
// 动态改变路由到状态管理
import { sync } from 'vuex-router-sync';
// ajax请求
import 'common/js/axios.js';
// iView UI框架
import iView from 'iview';
// iView 样式与主题
import 'common/less/iview-theme.less';
//ElementUI
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
//Mintui样式
import MintUI from 'mint-ui';
import 'mint-ui/lib/style.css';

import {Loading} from 'vux'
// 引入jQuery
import 'static/jquery/jquery.min.js';
// 引入rem
import '@/frame/Rem/rems.js';
// Mcake工具集
import '@/frame/Mcake/Mcake.js';

// 初始化路由状态
sync(store, router);

// 注册组件
Vue.use(iView);
Vue.use(ElementUI);
Vue.use(MintUI);
Vue.component('loading', Loading)
Vue.config.productionTip = false;


// 创建应用
let vm = new Vue({
    el: '#app',
    router,
    store,
    template: '<App/>',
    components: { App }
})